import request from '@/utils/request'


export function getUserList({ searchQuery, page, rows }) {
    return request.request({
        url: '/api/User/GetUserList',
        params: {
            searchQuery,
            page,
            rows
        },
        method: 'get'
    })
}

export function add(user) {
    return request.request({
        url: '/api/User/AddUser',
        method: 'post',
        data: user
    })
}

export function updateUser(user) {
    return request.request({
        url: '/api/User/UpdateUser',
        method: 'post',
        data: user
    })
}

export function getUserInfo(key) {
    return request.request({
        url: '/api/User/GetUserInfo',
        params: {
            key: key
        },
        method: 'get'
    })
}

export function deleteUser(users) {
    return request.request({
        url: '/api/User/DeleteUserByModels',
        method: 'post',
        data: users
    })
}



